<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/common/includes.jsp" %>

<html>

 <head>
    
    <title>出入库明细管理</title>
    <!-- import css and js -->
	<%@ include file="/common/meta.jsp" %>

		<script src="${ctx}/js/jsp/comm.js" type="text/javascript"></script>
    	<script type="text/javascript" src="${ctx}/js/jsp/yd/logic/storageDeatils1.js"></script>
	<script type="text/javascript">
		var basic_Url="${ctx}/yd/logic/storageDeatils";
		var basic_WUrl="/yd/logic/storageDeatils";
		var basic_Title="出入库明细管理";
		var show_Width=950;
		var show_Hight=400;
		function createSearch(){
			init(2,8,'140,140,140,140','25%');
			//第一行的数据
			addCommon(0,0,"lable","时间");
			addCommon(0,1,"date","a.dctime");
			addCommon(0,2,"lable","物料编号");
			addCommon(0,3,"txtlike","a.code");
			addCommon(0,4,"lable","物料名称");
			addCommon(0,5,"txtlike","m.name");
			addCommon(0,6,"lable","物料类型");
			addCommon(0,7,"txtlike","m.itmetype");
			addCommon(1,0,"lable","批次");
			addCommon(1,1,"txtlike","batch");
			addCommon(1,2,"lable","仓库");
			addCommon(1,3,"selectEnum","s.name","<option></option><c:forEach var="s" items="${wh}"><option value='${s.name}'>${s.name}</option></c:forEach>");
			addCommon(1,4,"lable","物料状态");
			addCommon(1,5,"selectEnum","e.status","<option value=''></option><option value='1'>一等</option><option value='2'>次品</option><option value='3'>旧品</option>"+
					"<option value='4'>冻结库存</option><option value='5'>在途库存</option>");
			
			
		}
		function searchAP(){			
			multipleSearch("#table1",true,"",basic_Url+"/listday.do");
		}
		
		function exportExcel(){
			var filtersStr = generateCondition();
			var path = basic_Url+"/exportExcelDay.do?filters="+filtersStr+"&_search=true";
		   	window.open(path,"_blank");
		}

	</script>
  </head>
<body onLoad="createSearch()">
   <div id="layout1">
      <div position="top">
      		<div class="panelBar">
          	<ul class="toolBar">
				   <li><a class="export" onclick="exportExcel()"><span>导出Excel</span></a></li>
               </ul>
          </div>
          <div id="pageHeader" class="pageHeader">
               <div class="searchBar" id="multipleSearchDialog">
	                <table class="table" width="100%" id="searchHeader" >  
                        <tbody id="newbody">
                        </tbody>
 	                </table>
                    <div class="subBar">
			             <ul>
				             <li><div class="buttonActive"><div class="buttonContent"><button type="submit" id="btnSearch" onclick="searchAP()">查询</button></div></div></li>
				             <li><a class="button" onclick="clearSearch()"><span>重置</span></a></li>
			             </ul>
	                </div>
               </div>
          </div>
      </div>
      <div position="center" id="table1">
      </div>
      <div class="clear"></div>
   </div>
 
</body>
</html>